Hole filling may be used by a computing device to support a variety of digital image processing. In one example, a missing portion of a digital image is replaced or restored, e.g., due to corruption of the digital image. In another example, an object in the digital image is replaced with another object. Thus, hole filling may be used by a computing device to restore digital images as well as create new art forms by replacing one object with another.
Conventional techniques to perform hole filling are faced with numerous challenges. Initially, fill techniques were developed in which a fill is generated by a computing device based on texture and color taken from other portions of the digital image. Although these techniques functioned well for digital images having simple textured backgrounds, these techniques often failed and thus looked unrealistic for structured or complex scenes.
Additional fill techniques were then developed. In these techniques, a search was made through an image repository (e.g., of stock digital images) to locate a digital image having content that is similar to content included in a digital image having a hole to be filled. However, in practice it may be difficult to locate a digital image that is sufficiently similar that may be used as a basis to fill the hole, such as due to differences in texture, parts that may provide a good match for a portion of the hole but not for other parts of the hole, and so forth. Thus, although conventional fill techniques may support additional functionality over previous fill techniques, these techniques may also fail to produce realistic results in real-world scenarios.